﻿using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ZiChen.SoXunLeiPan.Resources.Converters.ErrorConvert
{
    public class ErrorTypeToIconConverter : IValueConverter
    {
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            return (int)value switch
            {
                1 => "🌐",  // 网络
                2 => "🔍",  // 找不到
                3 => "👮",  // 审核
                4 => "🔧",  // 内部错误
                _ => "⚠️"
            };
        }

        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            throw new NotImplementedException();
        }
    }
}
